<?php

/* 
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

class NewsWidget extends CWidget
{
    public $actual;
    public $model;
    public function init()
    {
         parent::init();
         
         $this->model=News::getLastNews($this->actual);
             
    }
 
    public function run()
    {
        $this->render('NewsWidget/index',array('model'=>$this->model));
    }
}
